package com.bishe.demo.modules.ticket.dao;

import com.bishe.demo.modules.common.entity.City;
import com.bishe.demo.modules.ticket.entity.Model;
import org.apache.ibatis.annotations.*;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @Description ModelDao
 * @Author YHQ
 * @Date 2021/3/30 16:50
 */
@Repository
@Mapper
public interface ModelDao {

    @Select("SELECT model_id FROM train_model AS tm WHERE tm.start_point =#{startPoint} AND tm.end_point = #{endPoint} ")
    Integer getModelIdByStartPointandEndPoint(String startPoint,String endPoint);

    @Select("SELECT model_id FROM train_model WHERE model_name LIKE '%${modelName}%'")
    Integer getModelIdByModelName(String modelName);

    


}
